<?php
/**
 * Created by PhpStorm.
 * User: Administrator
 * Date: 2018/8/28
 * Time: 11:31
 */
namespace app\api\model;

class ProductImage extends BaseModel {

    protected $hidden = ['id','delete_time','product_id','img_id'];

    /**
     * product_image表关联 image表  一对一关系
     * @return \think\model\relation\BelongsTo
     */
    public function imgUrl(){
        return $this->belongsTo('Image','img_id','id');
    }
}